package com.h2cloud.testIO;

import java.io.File;
import java.io.FileInputStream;
import java.io.FileNotFoundException;
import java.io.IOException;

/**
 * @Package: com.h2cloud.testIO
 * @ClassName: test01
 * @Author: h2cloud
 * @CreateTime: 2021/6/17 3:35 下午
 * @Description:
 */
public class test01 {
    public static void main(String[] args) {
        File file;
        FileInputStream in = null;
        try {
            in = new FileInputStream("/Users/h2cloud/javaproject/javaStudy/src/main/java/com/h2cloud/testIO/test.txt");
            int b = 0;
            while ((b = in.read()) != -1) {
                System.out.println(b);
            }
        } catch (Exception e) {
            e.printStackTrace();
        } finally {

            try {
                in.close();
            } catch (IOException e) {
                e.printStackTrace();
            }
        }
    }
}
